package com.jy.adscm.operation.mscyb.controller;


import com.jy.adscm.exception.AdscmSystemException;
import com.jy.adscm.operation.mscyb.bean.JqzzPartsMaterial;
import com.jy.adscm.operation.mscyb.service.JqzzPartsMaterialService;
import com.jy.adscm.support.SimpleCoreResponse;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;

import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

/**
 * <p>
 *  前端控制器
 * </p>
 *
 * @author zyl
 * @since 2019-06-02
 */
@RestController
@RequestMapping("/adscm/operation/jqzz/jqzzPartsMaterial")
public class JqzzPartsMaterialController {
    @Autowired
    JqzzPartsMaterialService jqbzMaterialService;
    @RequestMapping("selectByTid/{tid}")
    public SimpleCoreResponse selectByTid(@PathVariable String tid) throws AdscmSystemException {
        List<JqzzPartsMaterial> jqbzMaterials= jqbzMaterialService.selectByTid(tid);
        return  new SimpleCoreResponse("200","查询成功",jqbzMaterials);
    }
}

